# Contributor: TBK <alpine@jjtc.eu>
# Maintainer: TBK <alpine@jjtc.eu>
pkgname=dislocker
pkgver=0.7.3
pkgrel=1
pkgdesc="Read/write Windows BitLocker-ed volumes"
url="https://github.com/Aorimn/dislocker"
arch="all"
license="GPL-2.0-or-later"
options="!check" # No test suite
makedepends="
	cmake
	fuse-dev
	mbedtls-dev
	ruby-dev
	samurai
	"
subpackages="$pkgname-doc $pkgname-libs"
source="$pkgname-$pkgver.tar.gz::https://github.com/Aorimn/dislocker/archive/v$pkgver.tar.gz
	fix-build.patch
	"

build() {
	cmake -B build -G Ninja \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_BUILD_TYPE=MinSizeRel

	cmake --build build
}

package() {
	DESTDIR="$pkgdir" cmake --install build
}

sha512sums="
c62241d70d51f6445a2f6d0f08e099bbc1a4257ca98232471fc43ec63e69d62ae5f702c995ec00b7e1db7d33f4bb3a31ea05bc13862bf3b539feb301a0e034ff  dislocker-0.7.3.tar.gz
7041559becbb5136d52b9494898ab3e315bdd7eddef7276e5f3f3cacd8a585718407d9fbcb9c589cc8702519d95cc4a37b6442358a5e8a3281ef5b05591295e6  fix-build.patch
"
